package com.android.baseconfig.base;

/**
 * ---------------------------------------------------------------- <br>
 * Copyright (C) 2014-2020, by het, Shenzhen, All rights reserved.  <br>
 * ---------------------------------------------------------------- <br>
 * <p>
 * 描述: DataApiResult <br>
 * 作者: lei <br>
 * 日期: 2018/5/15 <br>
 */
public class DataApiResult<T> {
    public Integer page;
    public Integer allpages;
    public Integer limit;
    public Integer total;
    public T rows;

    public int getTotal() {
        return total == null ? 0 : total;
    }

    public int getPage() {
        return page == null ? 0 : page;
    }

    public Integer getAllpages() {
        return allpages == null ? 0 : allpages;
    }

    @Override
    public String toString() {
        return "DataApiResult{" +
                "page=" + page +
                ", allpages=" + allpages +
                ", limit=" + limit +
                ", total=" + total +
                ", rows=" + rows +
                '}';
    }
}
